package org.example.wu_and_dian.controller;

import org.example.wu_and_dian.dto.request.RegisterDto;
import org.example.wu_and_dian.dto.response.AjaxResult;
import org.example.wu_and_dian.service.RegisterService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RestController;

@RestController
public class UserRegisterController {
    @Autowired(required = false)
    private RegisterService registerService;
    @PostMapping("/sign_up")
    public AjaxResult register(@RequestBody RegisterDto registerDto) {
        return registerService.register(registerDto);
    }
}
